//
//  XYPlayTools.h
//  Player
//
//  Created by 岁变 on 16/9/14.
//  Copyright © 2016年 岁变. All rights reserved.
//

#import <Foundation/Foundation.h>
#import <AVFoundation/AVFoundation.h>

//声明协议
@protocol XYPlayToolDelegate <NSObject>

//必须实现的方法

//传值
- (void)getCurrentTime:(NSString *)curTime totleTime:(NSString *)totleTime progress:(CGFloat)progress;

//播放结束
- (void)endOfPlayAction;


@end

@interface XYPlayTools : NSObject

@property (nonatomic, strong) AVPlayer *myPlayer;
@property (nonatomic, strong) NSArray *mp3URLArr;
@property (nonatomic, strong) NSString *mp3URL;

@property (nonatomic, assign) id <XYPlayToolDelegate> delegate;


//单例方法
+(instancetype)shareMyPlayer;
//播放音频
- (void)musicPlay;
//暂停音频
- (void)musicPause;
//准备播放
- (void)musciPreparePlay;
//跳转
-(void)seekToTimeWithValue:(CGFloat)value;


@end
